/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package hu.bme.j2ee.v37zen.web.beans;

import hu.bme.j2ee.v37zen.entities.User;
import javax.enterprise.context.SessionScoped;
import java.io.Serializable;
import javax.faces.bean.ManagedBean;

/**
 *
 * @author Kiss Dániel
 */
@ManagedBean(name ="UserManager_old")
@SessionScoped
public class UserManager implements Serializable {
    private static final long serialVersionUID = -8414917273021332315L;
    
//    @EJB
//    private FindUsersBean fub;
//    @EJB
//    private RegisterUserBean rub;
    
    private boolean error = false;
    private String username = "";
    private String password = "";
    
    private User user = null;

    /**
     * Creates a new instance of UserManager
     */
    public UserManager() {
    }
    
    
    public void login(){
        
        System.out.println("[SD-web] " + this.username + " " + this.password);
    }
    
    
    public boolean isError() {
        return error;
    }

    public void setError(boolean error) {
        this.error = error;
    }   

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public User getUser() {
        return user;
    }

    public void setUser(User user) {
        this.user = user;
    }
    
    
    
    
    
}
